package com.hpf.gupao.pattern.singleton.hungry;

/**
 * @description:
 * @datetime: 2021/5/17 20:03
 * @author: huangpengfei
 */
public class HungryStaticSingleton {

    // 先静态后动态
    // 先上后下
    // 先属性后方法
    private static final HungryStaticSingleton HUNGRY_SINGLETON;

    static {
        HUNGRY_SINGLETON = new HungryStaticSingleton();
    }

    private HungryStaticSingleton() {

    }

    public static HungryStaticSingleton getInstance() {
        return HUNGRY_SINGLETON;
    }
}
